package chapter04;

/**
 *判断网页请求与FPT请求
 * Created by a on 2017/6/9.
 */
public class Test068 {
    public static void main(String[] args) {
        String s = "f1tp1://www.baidu.com";
        if (s.startsWith("http")){
            System.out.println("http");
        }else if (s.startsWith("ftp")){
            System.out.println("ftp");
        }else {
            System.out.println("错误");
        }
    }
}
